home *** CD-ROM | disk | FTP | other *** search
- package java.util;
-
- final class ResourceBundle$CacheKey implements Cloneable {
- private String name;
- private Locale locale;
- private ResourceBundle.LoaderReference loaderRef;
- private String format;
- private volatile long loadTime;
- private volatile long expirationTime;
- private Throwable cause;
- private int hashCodeCache;
-
- ResourceBundle$CacheKey(String var1, Locale var2, ClassLoader var3) {
- this.name = var1;
- this.locale = var2;
- if (var3 == null) {
- this.loaderRef = null;
- } else {
- this.loaderRef = new ResourceBundle.LoaderReference(var3, ResourceBundle.access$200(), this);
- }
-
- this.calculateHashCode();
- }
-
- String getName() {
- return this.name;
- }
-
- ResourceBundle$CacheKey setName(String var1) {
- if (!this.name.equals(var1)) {
- this.name = var1;
- this.calculateHashCode();
- }
-
- return this;
- }
-
- Locale getLocale() {
- return this.locale;
- }
-
- ResourceBundle$CacheKey setLocale(Locale var1) {
- if (!this.locale.equals(var1)) {
- this.locale = var1;
- this.calculateHashCode();
- }
-
- return this;
- }
-
- ClassLoader getLoader() {
- return this.loaderRef != null ? (ClassLoader)this.loaderRef.get() : null;
- }
-
- public boolean equals(Object var1) {
- if (this == var1) {
- return true;
- } else {
- try {
- ResourceBundle$CacheKey var2 = (ResourceBundle$CacheKey)var1;
- if (this.hashCodeCache != var2.hashCodeCache) {
- return false;
- }
-
- if (!this.name.equals(var2.name)) {
- return false;
- }
-
- if (!this.locale.equals(var2.locale)) {
- return false;
- }
-
- if (this.loaderRef == null) {
- return var2.loaderRef == null;
- }
-
- ClassLoader var3 = (ClassLoader)this.loaderRef.get();
- return var2.loaderRef != null && var3 != null && var3 == var2.loaderRef.get();
- } catch (NullPointerException var4) {
- } catch (ClassCastException var5) {
- }
-
- return false;
- }
- }
-
- public int hashCode() {
- return this.hashCodeCache;
- }
-
- private void calculateHashCode() {
- this.hashCodeCache = this.name.hashCode() << 3;
- this.hashCodeCache ^= this.locale.hashCode();
- ClassLoader var1 = this.getLoader();
- if (var1 != null) {
- this.hashCodeCache ^= var1.hashCode();
- }
-
- }
-
- public Object clone() {
- try {
- ResourceBundle$CacheKey var1 = (ResourceBundle$CacheKey)super.clone();
- if (this.loaderRef != null) {
- var1.loaderRef = new ResourceBundle.LoaderReference((ClassLoader)this.loaderRef.get(), ResourceBundle.access$200(), var1);
- }
-
- var1.cause = null;
- return var1;
- } catch (CloneNotSupportedException var2) {
- throw new InternalError();
- }
- }
-
- String getFormat() {
- return this.format;
- }
-
- void setFormat(String var1) {
- this.format = var1;
- }
-
- private void setCause(Throwable var1) {
- if (this.cause == null) {
- this.cause = var1;
- } else if (this.cause instanceof ClassNotFoundException) {
- this.cause = var1;
- }
-
- }
-
- private Throwable getCause() {
- return this.cause;
- }
-
- public String toString() {
- String var1 = this.locale.toString();
- if (var1.length() == 0) {
- if (this.locale.getVariant().length() != 0) {
- var1 = "__" + this.locale.getVariant();
- } else {
- var1 = "\"\"";
- }
- }
-
- return "CacheKey[" + this.name + ", lc=" + var1 + ", ldr=" + this.getLoader() + "(format=" + this.format + ")]";
- }
-
- // $FF: synthetic method
- static Throwable access$400(ResourceBundle$CacheKey var0) {
- return var0.getCause();
- }
-
- // $FF: synthetic method
- static void access$500(ResourceBundle$CacheKey var0, Throwable var1) {
- var0.setCause(var1);
- }
-
- // $FF: synthetic method
- static long access$600(ResourceBundle$CacheKey var0) {
- return var0.expirationTime;
- }
-
- // $FF: synthetic method
- static long access$700(ResourceBundle$CacheKey var0) {
- return var0.loadTime;
- }
-
- // $FF: synthetic method
- static long access$702(ResourceBundle$CacheKey var0, long var1) {
- return var0.loadTime = var1;
- }
-
- // $FF: synthetic method
- static long access$602(ResourceBundle$CacheKey var0, long var1) {
- return var0.expirationTime = var1;
- }
- }
-